package cn.yougou.pojo;

import java.io.Serializable;
import java.util.Date;

/**
 * (YgComment)实体类
 *
 * @author 白杰崇
 * @since 2020-12-13 10:50:13
 */
public class YgComment implements Serializable {
    private static final long serialVersionUID = 700368925122644923L;
    /**
     * 主键
     */
    private Integer id;
    /**
     * 商品Id
     */
    private Integer commodityid;
    /**
     * 如果type=0，则是商品评论；如果是type=1，则是专题评论。
     */
    private Integer type;
    /**
     * 评论内容
     */
    private String content;
    /**
     * 管理员回复内容
     */
    private String admincontent;

    /**
     * 用户表的用户ID
     */
    private Integer userid;
    /**
     * 是否含有图片
     */
    private Integer haspicture;
    /**
     * 图片地址列表，采用JSON数组格式
     */
    private String picurls;
    /**
     * 评分， 1-5
     */
    private Integer star;
    /**
     * 创建时间
     */
    private Date addtime;
    /**
     * 更新时间
     */
    private Date updatetime;
    /**
     * 逻辑删除
     */
    private Integer deleted;

    public YgComment() {
    }

    public YgComment(Integer commodityid) {
        this.commodityid = commodityid;
    }


    public YgComment(Integer commodityid, Integer type, String content, Integer userid, Integer haspicture, String picurls, Integer star, Date addtime, Date updatetime, Integer deleted) {
        this.commodityid = commodityid;
        this.type = type;
        this.content = content;
        this.userid = userid;
        this.haspicture = haspicture;
        this.picurls = picurls;
        this.star = star;
        this.addtime = addtime;
        this.updatetime = updatetime;
        this.deleted = deleted;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getCommodityid() {
        return commodityid;
    }

    public void setCommodityid(Integer commodityid) {
        this.commodityid = commodityid;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getAdmincontent() {
        return admincontent;
    }

    public void setAdmincontent(String admincontent) {
        this.admincontent = admincontent;
    }

    public Integer getUserid() {
        return userid;
    }

    public void setUserid(Integer userid) {
        this.userid = userid;
    }

    public Integer getHaspicture() {
        return haspicture;
    }

    public void setHaspicture(Integer haspicture) {
        this.haspicture = haspicture;
    }

    public String getPicurls() {
        return picurls;
    }

    public void setPicurls(String picurls) {
        this.picurls = picurls;
    }

    public Integer getStar() {
        return star;
    }

    public void setStar(Integer star) {
        this.star = star;
    }

    public Date getAddtime() {
        return addtime;
    }

    public void setAddtime(Date addtime) {
        this.addtime = addtime;
    }

    public Date getUpdatetime() {
        return updatetime;
    }

    public void setUpdatetime(Date updatetime) {
        this.updatetime = updatetime;
    }

    public Integer getDeleted() {
        return deleted;
    }

    public void setDeleted(Integer deleted) {
        this.deleted = deleted;
    }

    @Override
    public String toString() {
        return "YgComment{" +
                "id=" + id +
                ", commodityid=" + commodityid +
                ", type=" + type +
                ", content='" + content + '\'' +
                ", admincontent='" + admincontent + '\'' +
                ", userid=" + userid +
                ", haspicture='" + haspicture + '\'' +
                ", picurls='" + picurls + '\'' +
                ", star=" + star +
                ", addtime=" + addtime +
                ", updatetime=" + updatetime +
                ", deleted='" + deleted + '\'' +
                '}';
    }
}